<?php
	//require_once __DIR__."/../Models/pics.php";
	
	//use Symfony\Component\HttpFoundation\Request;
	//use Symfony\Component\HttpFoundation\Response;

	//$pics_model = new Models\Pics($app);
	$pics_model = '';
	$pics = $app['controllers_factory'];

	$pics->get('/', function() use ($app, $pics_model) {
		/*
		$dir = __DIR__.'/../../views/imgsrc';	
		$pics_scan = scandir($dir);
		$pics = array();

		$user_var = $app['session']->get('user_var');

		foreach ($pics_scan as $value) {
			if( $value != '.' && $value != '..'  )
			$pics[] = array('src'=> $value);
		}

		$base_url = $app['homepage_route'];
		*/

		//return $app['twig']->render( 'pics1.html', array('pics_data'=>json_encode($pics), 'base_url'=>$base_url, 'user_var'=>$user_var ) );
		return $app['twig']->render( 'pics1.html' );
	});

	return $pics; 
?>